-
Notifications
You must be signed in to change notification settings - Fork 170
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
zoneconcierge: debugging API ChainInfo
#211
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. Some more info on the response would be useful though.
It would be nice if the explorer provided a page that listed all of the checkpoints for a particular epoch along with the status, but since we don't have that requirement right now, no reason to implement it yet.
// QueryChainInfoResponse is response type for the Query/ChainInfo RPC method. | ||
message QueryChainInfoResponse { | ||
// chain_info is the info of the CZ | ||
babylon.zoneconcierge.v1.ChainInfo chain_info = 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why don't we add further attributes here as with QueryFinalizedChainInfoResponse
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For example, epoch info and btc checkpoint info would be super useful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why don't we add further attributes here as with QueryFinalizedChainInfoResponse?
Since this API is only for debugging, it would be overkill to add stuff like inclusion proofs to this API. At the moment as long as the query gives us latest chain info then it should be enough for debugging.
For example, epoch info and btc checkpoint info would be super useful.
Such a latest chain info can be in an epoch that hasn't ended yet. To have these info the epoch with this chain info has to be at least submitted.
Yeah that would be very useful. To this end the ZoneConcierge needs to keep track of 1) the last submitted epoch, 2) the last confirmed epoch, and 3) the last finalised epoch. With these values the existing ZoneConcierge module can provide this functionality. Will add an issue for this 👍 |
This PR implements the API of getting the latest (non-BTC-finalised) chain info for a given chain ID. This API is useful for debugging.
@vitsalis getting BTC-submitted and BTC-confirmed chain info requires a lot more work (e.g., maintaining epoch status stuff in ZoneConcierge) and will only be helpful for debugging. I feel it's kind of not worth it. Wdyt?